import xmlrpclib

server = xmlrpclib.Server('http://ec2-50-16-47-119.compute-1.amazonaws.com:8000')
#print server.complete_trans('123')
print server.login('0', 'Derek', '123')
#print server.create_account('0', 'Derek', 'pw', 'a' , 'bc')
#print server.update_account('0', 'Derek', 'newpw', 'isnota' , 'nowiscbc')
#print server.get_account('0', 'Derek')
#print server.create_trans('0', 'Derek', 'prodname', 15.00, '11/15/2012')
#print server.get_trans('0', 0)
#print server.update_trans_with_buyer('0', 0, 'buyername')
#print server.delete_trans('0', '11111')
#print server.create_credit_card('0', 'Derek', '123456789', '11/21/2014', '123 abc street', 'apt 2012', 'durham', 'nc', '27708')
#print server.create_credit_card('0', 'Derek', '468122111', '01/14/1991', '1654 fgg street', 'apt 11', 'jobs', 'nc', '27518	')
#print server.update_credit_card(0, 'Derek', '987654321', '12/11/2014', '123 rera street', 'apt 11', 'chapel hill', 'nc', '27519')
#print server.get_credit_cards('0', 'Derek')
#print server.delete_credit_card(0, '123456789')
#with open("fetched.png", "wb") as handle:
#    handle.write(server.generate_qr().data)




